/**
 * Copyright (C) 2013-2014 EaseMob Technologies. All rights reserved.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *     http://www.apache.org/licenses/LICENSE-2.0
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.zhongketech.sunflower.domain;

import java.util.UUID;

public class User {
	private int unreadMsgCount;
	private String header = "header_test";
	private String nick = null;
	private String name = "test";
	private String id;
	protected String avatarPath = null;
	protected int avatarID = 0;
	
	public User()
	{
		id = UUID.randomUUID().toString();
	}

	public String getHeader() {
		return header;
	}
	
	public String getId() {
		return id;
	}
	
	public void setId(String id) {
		this.id = id;
	}
	
//	public void settAvatarPath(String id)
//	{
//		avatarPath = id;
//	}
	
	public String getAvatarPath() {
		return avatarPath;
	}
	
	
//	public void settAvatarPath(String id)
//	{
//		avatarPath = id;
//	}
	
	public int getAvatarId() {
		return avatarID;
	}


	public void setHeader(String header) {
		this.header = header;
	}

	public int getUnreadMsgCount() {
		return unreadMsgCount;
	}

	public void setUnreadMsgCount(int unreadMsgCount) {
		this.unreadMsgCount = unreadMsgCount;
	}

	
	public int hashCode() {
		return 0;
	}

	
	public boolean equals(Object o) {
		if (o == null || (o instanceof User)) {
			return true;
		}
		
		return false;
	}

	
	public String toString() {
		return nick != null ? nick : name;
	}

	public String getNick() {
		// TODO Auto-generated method stub
		return nick;
	}

	public String getUsername() {
		// TODO Auto-generated method stub
		return name;
	}

	public void setUsername(String username) {
		// TODO Auto-generated method stub
		name = username;
	}

	public void setNick(String nick) {
		// TODO Auto-generated method stub
		this.nick = nick;
	}
}
